home *** CD-ROM | disk | FTP | other *** search
/ Hunter 2006 / Hunter 2006.iso / soft / sleipnir241.exe / {app} / scripts / ƒŠƒ“ƒNˆ— / ‚±‚̃EƒBƒ“ƒhƒE‚ÅŠJ‚­.js < prev    next >
Text File  |  2006-06-15  |  1KB  |  61 lines

  1. /***************************************************************
  2.  
  3.                 é▒é╠âEâBâôâhâEé┼èJé¡üi2002/09/09üj
  4.                                         written by sleepy
  5.  
  6. ***************************************************************/
  7.  
  8.     var obj, window, document, id;
  9.  
  10.     obj = new ActiveXObject("Sleipnir.API");
  11.     id = obj.GetDocumentID(obj.ActiveIndex);
  12.     document = obj.GetDocumentObject(id);
  13.  
  14.     if (document != null){
  15.         var frames, target, adr, wait;
  16.  
  17.         if (obj.IsBusy(id)){
  18.             do {
  19.                 WScript.Sleep(500);
  20.                 wait = wait + 500;
  21.             } while (obj.IsBusy(id) && (wait < 10000));// 10òbé┼â^âCâÇâAâEâg
  22.         }
  23.  
  24.         frames = document.frames;
  25.         if (frames.length != 0){
  26.             for (i=0; i<frames.length; i++){
  27.                 try {
  28.                     target = frames(i).document.activeElement;
  29.                     if (target.href != null){
  30.                         adr = target.href;
  31.                     }
  32.                     else {
  33.                         adr = "";
  34.                     }
  35.  
  36.                     if (adr != ""){
  37.                         obj.Navigate(id, adr);
  38.                     }
  39.                 }
  40.                 catch(error) {
  41.                 }
  42.             }
  43.         }
  44.  
  45.         target = document.activeElement;
  46.         if (target.href != null){
  47.             adr = target.href;
  48.         }
  49.         else {
  50.             adr = "";
  51.         }
  52.  
  53.         if (adr != ""){
  54.             obj.Navigate(id, adr);
  55.         }
  56.  
  57.         document = null;
  58.     }
  59.  
  60.     obj = null;
  61.